<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
		<meta name="google" content="notranslate">
		<meta http-equiv="X-UA-Compatible" content="IE=edge">
		<title>文件预览</title>
	</head>
	<style>
		.frame_wrap {
			position: fixed;
			width: 100%;
			height: 100%;
			left: 0;
			top: 0;
			border: none;

		}
	</style>
	<body>
		<iframe class="frame_wrap" src="./web/viewer.html?file=" id="myframe"></iframe>
	</body>
</html>
<script>
	document.getElementById("myframe").src="./web/viewer.html?file="+getQueryVariable("file");
	
	function getQueryVariable(variable) {
		var query = window.location.search.substring(1);
		var vars = query.split("&");
		for (var i = 0; i < vars.length; i++) {
			var pair = vars[i].split("=");
			if (pair[0] == variable) {
				return pair[1];
			}
		}
		return (false);
	}
</script>
